package com.wll.design.观察者.eventbus;

import com.google.common.eventbus.Subscribe;

/**
 * @ClassName: EventListener.java
 * @author: wanglulu
 * @version: 1.0.0
 * @Description: 事件监听
 * @createTime: 2021/11/25 15:46
 */
public class EventListener {

    /**
     * 加了订阅，这里标记这个方法是事件处理方法
     * @param notifyEvent
     */
    @Subscribe
    public void handle(NotifyEvent notifyEvent) {
        System.out.println("发送IM消息" + notifyEvent.getImNo());
        System.out.println("发送短信消息" + notifyEvent.getMobileNo());
        System.out.println("发送Email消息" + notifyEvent.getEmailNo());
    }

}
